<?xml version="1.0" encoding="utf-8"?>

<xsl:stylesheet version="1.0"
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:template match="/">
  <feeds>
    <xsl:for-each select="/feeds/feed[tag/@value='sites amis']">
      <xsl:if test="position()&lt;=15">
       <xsl:call-template name="tplCopyFeed"/>
      </xsl:if>
    </xsl:for-each>
    <xsl:for-each select="/feeds/feed[not(tag/@value='sites amis')]">
      <xsl:if test="position()&lt;=10">
        <xsl:call-template name="tplCopyFeed"/>
      </xsl:if >
    </xsl:for-each>
  </feeds>  
</xsl:template>

  <xsl:template name="tplCopyFeed">
    <feed name="{@name}" updated="{@updated}" siteurl="{@siteurl}" feedurl="{@feedurl}" li_date="{@li_date}" li_title="{@li_title}"/>
  </xsl:template>

</xsl:stylesheet> 

